<template>
<div class="form">
    <Tabs type="card" :animated="false">
        <Tab-pane :label="item.label" v-model="item.name" v-for="(item,i) in tabData" :key="i" @click="tabIndex(i)" class="tabpane">
            <RegisterUser v-if="tabIndexs === i"></RegisterUser>
            <RegisterEnterprise v-else></RegisterEnterprise>
        </Tab-pane>
        <!-- <TabPane label="企业用户"></TabPane> -->
    </Tabs>
</div>
</template>

<script>
import RegisterUser from '@/pages/register/list/RegisterUser'
import RegisterEnterprise from '@/pages/register/list/RegisterEnterprise'
export default {
    name: 'RegisterMain',
    components: {
        RegisterEnterprise,
        RegisterUser
    },
    data() {
        return {
            tabData: [{
                    label: "个人用户",
                },
                {
                    label: '企业用户',
                }
            ],
            tabIndexs: 0,
        }
    },
    methods: {
        tabIndex(index) {
            this.tabIndexs = index
        }
    },

}
</script>

<style lang="less" scoped>
 
</style>
